<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<style type="text/css">
		*{
			margin: 0;
			padding: 0;
		}
		#box{
			width: 1270px;
			height: 690px;
			position: relative;
			top: 50px;
			margin: 0 auto;
			background: url(img/yc.jpg);
		}
		img{
			position: absolute;
			top: -50px;
		}
	</style>
</head>
<body>
	<div id="box">
		<div id="money">
			<img src="img/jb.png">
		</div>
	</div>
</body>
<script type="text/javascript">
	var box=document.getElementById("box");
	var money=document.getElementById("money");
	var imgs=document.getElementsByTagName("img");
	function yx(){
		// var imgs=document.createElement("img");
		imgs[0].style.top=640+"px"-10+"px";
		
	}
	yx();
	setInterval(yx,1000);
	// 随机数
	function rand(min,max){
		return parseInt(Math.random()*(max-min))+min;
	}
</script>
</html>